<html>
<head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <link href="<?php echo base_url(); ?>css/admincp.css" type="text/css" rel="stylesheet" />
    <script src="<?php echo base_url(); ?>script/jquery-1.6.2.min.js" type="text/javascript"></script>
    <script type="text/javascript" src="<?php echo base_url(); ?>script/jadmin.js"></script>
    <script type="text/javascript">
        function doDelete(id, hideid){
            deleteMovieChoice(id);
            $("#"+hideid).hide();
        }
    </script>
</head>
<body>
<?php
if(isset($list)){
    echo '<ul>';
    foreach($list as $item){
        $id = $item['id'];
        $movieID = $item['movie_id'];
        $name = $item['name'];
        $img = base_url().$item['image'];
        $delete = base_url().'manage/movie/choice/addnew.html';
        $liID = 'hideid' . $id;
        echo "
        <li id='$liID'>
        <img src=\"$img\" alt=\"\" />
        $name
        <span onclick=\"doDelete($id,'$liID');\"><a href=\"#\">Delete</a></span>
        </li>
        ";
    }
    echo '</ul>';
}
?>
</body>